package com.example.module_mine.login.loginnet

import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.flow.flow
import kotlinx.coroutines.flow.flowOn
import javax.inject.Inject

class LoginRePo @Inject constructor() {
    @Inject
    @MineNetMoudle.CommonMineApi
    lateinit var mineApi: MineApi

    fun login(username: String, password: String) =
       flow {
           emit(mineApi.login(username, password))
       }.flowOn(Dispatchers.IO)
}